package com.caocaog.market.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.caocaog.market.entity.GoodsBase;
import com.caocaog.market.entity.vo.GoodsVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 商品基础信息
 *
 * @author chechen
 * @date 2022-04-21
 */
public interface GoodsBaseMapper extends BaseMapper<GoodsBase> {

    IPage<GoodsBase> queryGoodsBasePage(Page<GoodsBase> page, @Param("goodsBasic") GoodsBase goodsBase);

    List<GoodsBase> getGoodsBaseByCategoriesId(@Param("categoriesId") String categoriesId);

    /**
     * 连表根据频道Id查询出全部的商品信息
     * @param channelId 频道Id
     * @return 查询到的商品信息
     */
    List<GoodsBase> selectAllGoodsByChannelId(String channelId);
}
